// pages/doctor-news-details/doctor-news-details.js
var app = getApp();
var WxParse = require('../../wxParse/wxParse.js');
Page({

  /**
   * 页面的初始数据
   */
  data: {
    diaryinfo:"", 
  },

  /**
   * 生命周期函数--监听页面加载
   */
  onLoad: function (options) {
    var id = options.id;
    var that = this;
    app.request({
      url: 'system/officialapi/officialdetail',
      data: {
        id: id,
      },
      success(res) {
        var article = res.data.content;
        that.setData({
          diaryinfo: res.data,
        })
        WxParse.wxParse('article', 'html', article, that, 5);
      }
    })   
  }
})